<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<div id="app">
    <p>引用子组件</p>
    <hello></hello>
</div>
</body>
<script src="node_modules/vue/dist/vue.js"></script>
<script>
    const hello = {
        template: "<div>are you ok --{{name}}</div>",
        data() {
            return {
                name: "雷布斯"
            }
        }
    }

    const app = new Vue({
        el: "#app",
        data: {
            num: 0
        },
        //该组件所包含的子组件
        components: {
            //key除了第一个字母可以大写，后面的全部用小写
            hello: hello  //key对应的值既是在外面声明的组件
        }
    })
</script>
</html>